package day2;

/**
 * @author oldliu
 * @since 1.0
 */
public class ForTest {
    public static void main(String[] args) {
        String str="";
        long start=System.nanoTime();
        for(int i=1;i<=10000;i++){
            str+=i;
        }
        long end=System.nanoTime();
        System.out.println((end-start)+"纳秒");
        StringBuilder sb=new StringBuilder();
        for(int i=1;i<=10000;i++) {
            sb.append(Math.PI);
            sb.append(Math.sqrt(8));
            sb.append(2 > 65);
            sb.append("你好");
            //System.out.println(sb);
            //sb.insert(6, "oldliu");
            //System.out.println(sb);
            sb.delete(9, 12);
            sb.append("王涛").append("东兴").append("瑶海一霸");
           // System.out.println(sb);
           // sb.reverse();
        }
        long end2=System.nanoTime();
        System.out.println(end2-end+"纳秒");
        //System.out.println(sb);
        System.out.println(sb.length());
        String s8=String.valueOf(sb);
    }
}
